<%@ include file="/common/include.jsp" %>

<head>
	<style type="text/css">
		.metricsBox {
			width: 400px;
			height: 100px;
			border: solid 1px #A8A8A8;
			font-size: 12px;
			font-family: Trebuchet MS, URW Gothic L, Verdana, Helvetica, sans-serif;
			overflow: auto;
		}
		
		.metricsBox table {
			width: 400px;
			text-align: left;
			font-size: 12px;
			font-family: Trebuchet MS, URW Gothic L, Verdana, Helvetica, sans-serif;
		}
		
		.metricsBox input {
			border: solid 1px #A8A8A8;
			font-size: 11px;
			font-family: Trebuchet MS, URW Gothic L, Verdana, Helvetica, sans-serif;
		}
		
	</style>
</head>

<h3>Contribution Model</h3>

<p>
	This service allows you to calculate a contribution measure based in the classic metrics of size and quality of software and the performed activities in the bug tracker systems.
	The results of contribution for each developer are calculated on two factors: a <b>size contribution factor</b> and a <b>quality contribution factor</b>. The <b>size contribution 
	factor</b> is defined as a weighted sum of a set of metrics of contributions performed on the version control system and the bugtracker system, while the <b>quality contribution 
	factor</b> is defined only on the version control system. The first set of metrics measures the effort associated to the implementation of source code while the second set 
	measures the quality of these effort. For view more information <a href="http://code.google.com/p/devmeter/downloads/list">click here</a>.
</p>

<table width="600">
	<tr>
		<td class="subtitleModel">Select a Size Metric</td>
		<td></td>
		<td class="subtitleModel">Included Size Metrics</td>
	</tr>
	<tr>
		<td align="center">
			<s:select name="metricsSourceSize" list="%{sizeMetrics}" multiple="true" size="5" cssClass="metricsBox" id="sourceSize" theme="simple" />
		</td>
		<td align="center">
			<input type="button" value=">>" onclick="addMetric('sourceSize', 'destinationSize', 'classSize')" />
		</td>
		<td align="center">
			<div class="metricsBox">
				<table id="destinationSize" cellspacing="0">
			
				</table>
			</div>
		</td>
	</tr>
</table>

<table width="600">
	<tr>
		<td class="subtitleModel">Select a Quality Metric</td>
		<td></td>
		<td class="subtitleModel">Included Quality Metrics</td>
	</tr>
	<tr>
		<td align="center">
			<s:select name="metricsSourceQuality" list="%{qualityMetrics}" multiple="true" size="5" cssClass="metricsBox" id="sourceQuality" theme="simple" />
		</td>
		<td align="center">
			<input type="button" value=">>" onclick="addMetric('sourceQuality', 'destinationQuality', 'classQuality')" />
		</td>
		<td align="center">
			<div class="metricsBox">
				<table id="destinationQuality" cellspacing="0">
			
				</table>
			</div>
		</td>
	</tr>
</table>

<tr>
	<td>
		<input type="button" value="Calculate" onclick="calculateModel()" />
	</td>
</tr>

<div id="results-div" style="display:none; height: 250px; overflow: auto; padding: 10px;">
	<h3>Results</h3>
	<table id="results-table" class="tableReport" cellspacing="0" >
	
	</table>
	
	<input type="button" value="Accept" onclick="hideResultsTable()" />
	<input type="button" value="Export" id="results-button" />
</div>